package cn.mesmile.flow.listen;

import org.flowable.common.engine.api.delegate.Expression;
import org.flowable.engine.delegate.DelegateExecution;
import org.flowable.engine.delegate.JavaDelegate;

/**
 * @author zb
 * @date 2021/2/5 14:11
 * @Description
 *
 *      Java Service Task  flowable:class="cn.mesmile.flow.listen.MyJavaServiceTask"
 */
public class MyJavaServiceTask implements JavaDelegate {

    /**
     * <serviceTask id="javaService"
     *     name="Java service invocation"
     *     flowable:class="cn.mesmile.flow.listen.MyJavaServiceTask">
     *     <extensionElements>
     *       <flowable:field name="text" stringValue="Hello World" />
     *   </extensionElements>
     * </serviceTask>
     *
     */

    private Expression text;

    @Override
    public void execute(DelegateExecution execution) {

        Object value = text.getValue(execution);

        String processInstanceId = execution.getProcessInstanceId();


    }


}
